<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8" %>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
<html>
<head>
    <meta charset="utf-8">
    <title>订单信息</title>
    <link rel="stylesheet" href="${pageContext.request.contextPath}/css/bootstrap.css">
    <link rel="stylesheet" href="${pageContext.request.contextPath}/css/AdminLTE.css">
    <link rel="stylesheet" href="${pageContext.request.contextPath}/css/pagination.css">
    <script src="${pageContext.request.contextPath}/js/jquery.min.js"></script>
    <script src="${pageContext.request.contextPath}/js/bootstrap.js"></script>
    <script src="${pageContext.request.contextPath}/js/pagination.js"></script>
    <script src="${pageContext.request.contextPath}/js/my.js"></script>
</head>

<body class="hold-transition skin-red sidebar-mini">
<!-- .box-body -->
<div class="box-header with-border">
    <h3 class="box-title">订单信息</h3>
</div>
<div class="box-body">
    <div class="table-box">
        <!-- 数据表格 -->
        <table id="dataList" class="table table-bordered table-striped table-hover dataTable text-center">
            <thead>
            <tr>
                <th class="sorting">订单编号</th>
                <th class="sorting">药品编号</th>
                <th class="sorting">顾客编号</th>
                <th class="sorting_">工作人员</th>
                <th class="sorting">购买数量</th>
                <th class="sorting">用途</th>
            </tr>
            </thead>
            <tbody>
            <c:forEach items="${pageInfos.list}" var="medicine">
                <tr>
                    <td>${medicine.bid}</td>
                    <td>${medicine.mid}</td>
                    <td>${medicine.cid}</td>
                    <td>${medicine.uid}</td>
                    <td>${medicine.num}</td>
                    <td>${medicine.csymptom}</td>
                </tr>
            </c:forEach>
            </tbody>
        </table>
        <!--数据表格/-->
        <div class="box-tools pull-right">
            <ul class="pagination">
                            <li><a href="${pageContext.request.contextPath}/searchBuy?page=1&size=5" aria-label="Previous">首页</a></li>
                            <li>
                                <c:if test="${pageInfos.pageNum>1}">
                                <a href="${pageContext.request.contextPath}/searchBuy?page=${pageInfos.pageNum-1}&size=5">
                                上一页
                            </a>
                                </c:if></li>
                            <c:forEach begin="1" end="${pageInfos.pages}" var="pageNumber">
                                <li><a href="${pageContext.request.contextPath}/searchBuy?page=${pageNumber}&size=5">${pageNumber}</a></li>
                            </c:forEach>
                            <li>
                                <c:if test="${pageInfos.pageNum<pageInfos.pages}">
                                    <a href="${pageContext.request.contextPath}/searchBuy?page=${pageInfos.pageNum+1}&size=5">下一页</a>
                                </c:if></li>
                            <li><a href="${pageContext.request.contextPath}/searchBuy?page=${pageInfos.pages}&size=5" aria-label="Next">尾页</a></li>
                        </ul>
        </div>
    </div>
</div>
</body>
</html>